let Upload = document.getElementById('upload');
let imgEle = document.getElementById('img');
Upload.onclick = function(event){
    imgEle.click();
    // return false;
    event.preventDefault();
}
imgEle.onchange = function () {
    let file = this.files[0]
    // 判断上传文件，没有上传就退出
    if (!file) {
        return
    }
    let fileReader = new FileReader()
    fileReader.readAsDataURL(file)
    fileReader.onload = function (e) {
        document.getElementById('preview').src = this.result;
        document.getElementById('imgWrap').style.display = '';
    }
}